<include file="Public:head" />
<style>

    .table-striped tr  .td_dan{
        line-height: 30px;text-align: right;width: 50px
    }
    .width20{
        width: 260px;
    }
</style>
<body class="overflow-hidden">
<div class="wrapper preload">
    <include file="Public:header" />
    <include file="Public:left" />
    <div class="main-container">
        <div class="padding-md">
            <div class="row">
                <div class="col-sm-12">
                    <div class="page-title">
                        {$info['id']?'编辑':'新增'}行为
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="col-lg-12">
                    <div class="smart-widget widget-green">
                        <form action="{:U('saveAction')}" method="post" class="form-admin14">
                            <table class="table table-striped no-margin" >
                                <tr >
                                    <td  style="width: 10%;text-align: right;line-height: 34px">行为标识</td>
                                    <td >
                                        <input type="text" class="form-control width20" name="name" value="{$info.name}">
                                        <span style="line-height: 34px">（输入行为标识 英文字母）</span>
                                    </td>
                                </tr>
                                <tr >
                                    <td  style="width: 10%;text-align: right;line-height: 34px">行为名称</td>
                                    <td >
                                        <input type="text" class="form-control width20" name="title" value="{$info.title}">
                                        <span style="line-height: 34px">（输入行为名称）</span>
                                    </td>
                                </tr>
                                <tr >
                                    <td  style="width:10%;text-align: right;line-height: 34px">行为类型</td>
                                    <td >
                                        <select name="type" class="form-control width20">
                                            <volist name=":get_action_type(null,true)" id="vo">
                                                <option value="{$key}">{$vo}</option>
                                            </volist>
                                        </select>
                                        <span style="line-height: 34px">（选择行为类型）</span>
                                    </td>
                                </tr>
                                <tr >
                                    <td  style="width:10%;text-align: right;line-height: 34px">行为描述</td>
                                    <td >
                                        <textarea name="remark" class="form-control width20">{$info.remark}</textarea>
                                        <span style="line-height: 34px">（输入行为描述）</span>
                                    </td>
                                </tr>
                                <tr >
                                    <td  style="width: 10%;text-align: right;line-height: 34px">行为规则</td>
                                    <td >
                                        <textarea name="rule" class="form-control width20">{$info.rule}</textarea>
                                        <span style="line-height: 34px">（输入行为规则，不写则只记录日志）</span>
                                    </td>
                                </tr>
                                <tr >
                                    <td  style="width: 10%;text-align: right;line-height: 34px">日志规则</td>
                                    <td >
                                        <textarea name="log" class="form-control width20">{$info.log}</textarea>
                                        <span style="line-height: 34px">（记录日志备注时按此规则来生成，支持[变量|函数]。目前变量有：user,time,model,record,data）</span>
                                    </td>
                                </tr>
                                <tr class="result_list">
                                    <td>&nbsp;</td>
                                    <td>
                                        <input type="hidden" name="id" value="{$info.id}"/>
                                        <button type="submit" class="action-button ajax-post" target-form="form-admin14">确 定</button>
                                        <button class="action-button" onclick="javascript:history.back(-1);return false;">返 回</button>
                                    </td>
                                </tr>
                            </table>
                        </form>
                    </div><!-- ./smart-widget -->
                </div><!-- ./col -->
            </div><!-- ./row -->
        </div><!-- ./padding-md -->
    </div><!-- /main-container -->
    <include file="Public:foot" />
</div><!-- /wrapper -->
<!--<include file="Public/base_fc" />-->
<a href="#" class="scroll-to-top hidden-print"><i class="fa fa-chevron-up fa-lg"></i></a>
</body>
</html>
<block name="script">
    <script>
        $(function(){
            highlight_nav2('{:U("User/userAction")}');

        })
    </script>
</block>
